package jhavelogger.parser;

import java.util.HashSet;

import junit.framework.Assert;

import org.junit.Before;
import org.junit.Test;

public class UidOperationTests extends LogFactoryTestingBase {

    private HashSet<LogMessageType> allowedLogMessageTypes;

    @Before
    public void setUp() throws Exception {
	super.setUp();
	this.factory = new UidOperationFactory();
	this.allowedLogMessageTypes = new HashSet<LogMessageType>();
	this.allowedLogMessageTypes.add(LogMessageType.UIDOPERATION);
    }

    @Test
    public void parsesAcceptedConnectionLog() {
	Assert.assertTrue(this.factoryCreatesObject(LogMessageType.UIDOPERATION));
    }

    @Test
    public void doesNotParseOtherLogs() {
	Assert.assertNull(this.factoryDoesNotCreateObjectsOfTypesOtherThan(this.allowedLogMessageTypes));
    }
}
